﻿using System.ComponentModel.DataAnnotations;
using BLL.CustomAttribute;
using BLL.Utility;

namespace BLL.Model.OperatingSystem
{
    /// <summary>
    /// 操作系统信息
    /// </summary>
    public class OperatingSystemInfo
    {
        [Key, StringProperty]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        public int Id { get; set; }

        [Display(Name = "系统名称"), StringLength(200), Required(AllowEmptyStrings = false), StringProperty]
        public string Name { get; set; }

        [Display(Name = "系统版本"), StringLength(200), StringProperty]
        public string Version { get; set; }

        [Display(Name = "备注"), DataType(DataType.MultilineText)]
        public string Comment { get; set; }

        public override string ToString()
        {
            return ModelHelper<OperatingSystemInfo>.AutoCreateModelString(this);
        }

    }
}